{% extends "base.html" %} {% block title %}添加图书{% endblock %} {% block
content %}
<div class="page">
  <form method="post">
    <div class="weui-form">
      <div class="weui-form__bd">
        <div class="weui-form__text-area">
          <h2 class="weui-form__title">图书上传说明</h2>
          <div class="weui-form__desc">
            可将自己闲置的图书上传到平台，分享给他人阅览
          </div>
        </div>

        <div class="weui-form__control-area">
          <div class="weui-cells__group weui-cells__group_form">
            <input
              type="hidden"
              name="authenticity_token"
              value="{{ authenticity_token }}"
            />
            <!-- 名称、出版社、ISBN -->
            <div class="weui-cells__title">新增图书</div>
            <div class="weui-cells">
              <label for="js_input1" class="weui-cell weui-cell_active">
                <div class="weui-cell__hd">
                  <span class="weui-label">图书名称</span>
                </div>
                <div class="weui-cell__bd">
                  <input
                    id="js_input1"
                    class="weui-input"
                    placeholder="填写图书名称"
                    name="name"
                  />
                </div>
              </label>
              <label for="js_input2" class="weui-cell weui-cell_active">
                <div class="weui-cell__hd">
                  <span class="weui-label">出版社</span>
                </div>
                <div class="weui-cell__bd">
                  <input
                    id="js_input2"
                    class="weui-input"
                    placeholder="填写图书出版社"
                    name="press"
                  />
                </div>
              </label>
              <label for="js_input3" class="weui-cell weui-cell_active">
                <div class="weui-cell__hd">
                  <span class="weui-label">ISBN</span>
                  <div class="weui-cell__desc">序列号</div>
                </div>
                <div class="weui-cell__bd">
                  <input
                    id="js_input3"
                    class="weui-input"
                    placeholder="填写图书序列号"
                    type="text"
                    name="isbn"
                  />
                </div>
              </label>
            </div>
            <div
              role="alert"
              id="js_current_tips"
              style="display: block"
              class="weui-cells__tips weui-cells__tips_warn"
            >
              {{err}}
            </div>
          </div>
        </div>
      </div>
      <div class="weui-form__ft">
        <div class="weui-btn-area">
          <button type="submit" class="weui-btn weui-btn_primary">确定</button>
        </div>
      </div>
    </div>
  </form>
</div>
{% endblock %}
